package Demo;

public class Demo6 {
    public static void main(String[] args) {
        outter.inner inner = new outter().new inner();
        outter out = new outter();
        out.age = 10;
        out.out();
        inner.in();
        new info() {//匿名对象
            public void info() {
                System.out.println("+++++++++++++++++++++++");
            }
        }.info();
    }
}

class outter {
    int age = 10;

    public void out() {
        System.out.println(+age + "++++++++++++++++++");
    }

    class inner {
        public void in() {
            System.out.println(age + "+++++++++++++++++++++++++");
        }
    }
}

abstract class info {
    public void info() {
    }

}
